<template>
	<view class="custom-icon">
		<icon class="icon iconfont"
			:class="[icon]"
		></icon>
	</view>
</template>

<script setup>
import { computed } from 'vue';
	const props = defineProps({
		icon: {
			type: String
		},
		size: {
			type: String,
			default: '32'
		}
	})
	
	const style = computed(() => {
		return {
			...(props.size ? {'font-size': props.size + 'rpx'} : {})
		}
	})
</script>

<style lang="less" scoped>
	@import './style/index.less';
</style>